/**
 * 
 */
package com.ims.stocks.dao.address;

import java.util.List;

import com.ims.common.dao.BaseDAOHibImpl;
import com.ims.stocks.model.Address;
import com.ims.stocks.model.Employee;

/**
 * @author Achal B.I
 *
 */
public class AddressDAOImpl extends BaseDAOHibImpl implements AddressDAO {

	public List<Address> getAddressesOfPerson(int id){
		org.hibernate.Query q = getHibernateTemplate().getSessionFactory().getCurrentSession().createQuery("from Address where Person_Id = :Person_Id ");
		q.setParameter("Person_Id", id);
		List<Address> addressList = (List<Address>)q.list();
		return addressList;
	}
}
